/*
 * Spring 2012 TCSS360 Deliverable 3
 * Otis Alexander
 */

package model;

import java.util.HashMap;
import java.util.Map;

public class UserAccess {

	private Map<String, User> users;

	public UserAccess() {
		users = new HashMap<String, User>();
	}

	public void addUser(final User u) {
		users.put(u.getUserName(), u);
	}

	public Map<String, User> getUsers() {
		return users;
	}

	public int login(final String userName) {
		return users.get(userName).getAccessLevel();
	}
}
